package com.example.shop.pojo;

import com.baomidou.mybatisplus.annotation.*;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import lombok.*;
import lombok.experimental.Accessors;

/**
* <p>
* 用户地址簿：收件人、寄件人
* </p>
*
* @author 作者
* @since 2022-05-29
*/
@Data
@NoArgsConstructor
@AllArgsConstructor
@Accessors(chain = true)
@TableName("r_user_address_book")
public class UserAddressBook extends Model<UserAddressBook> {

    private static final long serialVersionUID = 1L;

    @TableId(value = "linkman_id", type = IdType.AUTO)
    private Long linkmanId;

    @TableField(whereStrategy = FieldStrategy.NOT_EMPTY)
    private Long userId;
    //联系人的头像
    private String linkmanPicture;
    //联系人名
    private String linkmanName;
    //联系人电话
    private String linkmanPhone;
    //联系人地区
    private String linkmanArea;
    //联系人详细地址
    private String detailedAddress;
    //联系人的经度
    private double linkmanLongitude;
    //联系人的纬度
    private double linkmanLatitude;

    @Override
    public String toString() {
        return "UserAddressBook{" +
                "linkmanId=" + linkmanId +
                ", userId=" + userId +
                ", linkmanPicture='" + linkmanPicture + '\'' +
                ", linkmanName='" + linkmanName + '\'' +
                ", linkmanPhone='" + linkmanPhone + '\'' +
                ", linkmanArea='" + linkmanArea + '\'' +
                ", detailedAddress='" + detailedAddress + '\'' +
                ", linkmanLongitude=" + linkmanLongitude +
                ", linkmanLatitude=" + linkmanLatitude +
                '}';
    }
}
